<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<script>
function Person(){
    this.name = 'frank'
}
Person.prototype.say = function(){
    alert('你好');
}

//var p = new Person();

function Human(){
 this.age = 10;
}
//Human.prototype = p;

//function myCreate(a){
//    var to;
//    function F(){}
//    F.prototype = a;
//    to = new F();
//    return to;
//}
//var p = myCreate(Person.prototype);


Human.prototype = Object.create(Person.prototype);

var h = new Human();

</script>
</body>
</html>